<!DOCTYPE html>
<head lang="en">
    <meta charset="UTF-8">
    <title>会员编辑</title>
    <!--主样式css-->
    <link type="text/css" href="../css/bootstrap.min.css" rel="stylesheet">


</head>
<body style="padding: 10px;" ng-app="myApp" ng-controller="customerTemplateCtrl">
<header ng-include="'../html/part/header.html'" class="abs-header"></header>
<br><br><br>

<h2>会员列表</h2>
<h4 ng-hide="customers.length>0">还没有会员，是否添加？</h4>

<div>
    搜索：<input type="text" ng-model="titleFilter" placeholder="输入关键字">
</div>
<br>
<table class="imagetable" width="100%">
    <tr ng-hide="customers.length==0">
        <th>会员号</th><th>手机号</th><th>积分</th><th>姓名</th><th>性别</th><th>年龄</th><th>注册日期</th><th>操作</th>
    </tr>
    <tr ng-repeat="customer in customers|filter:titleFilter">

        <td>{{customer.num}}</td>
        <td>{{customer.phone}}</td>
        <td>{{customer.score}}</td>
        <td><a href = cusSpend.html?num={{customer.num}}>{{customer.name}}</a></td>
        <td>{{customer.sex=1?"男":"女"}}</td>
        <td>{{customer.age}}</td>
        <td>{{customer.registerDate| date:'yyyy-MM-dd'}}</td>
        <td>
            <!--<a ng-click="saveMenuTemplate(customer.num,customer.phone,customer.name,customer.sex,customer.age)">保存</a>-->
            <a ng-click="deleteTemplate(customer.num,$index)">删除该会员</a>
        </td>
    </tr>
</table>
<br><br>
<div class="bottom-right">
    <button ng-click="addMenuTemplate()" class="btn btn-info">添加会员</button>
</div>

<br><br><br>
<footer ng-include="'../html/part/footer.html'"></footer>
</body>
<script type="text/javascript" src="../lib/angular/angular.min.js"></script>
<script type="text/javascript" src="../lib/angular/angular-cookies.js"></script>
<script type="text/javascript" src="../lib/angular/angular-ui-router.min.js"></script>
<script type="text/javascript" src="../js/controller/services/model.js"></script>
<script type="text/javascript" src="../js/controller/customerTemplate.ctrl.js"></script>
</html>